
# =====================================
# solve error：UnicodeEncodeError: 'gbk' codec can't encode character '\xXX' in position XX
# =====================================
import io
import sys
sys.stdout = io.TextIOWrapper(sys.stdout.buffer,encoding='gb18030') #改变标准输出的默认编码

import requests

url = 'https://inv-veri.chinatax.gov.cn/'
#url = 'http://www.baidu.com'

resp = requests.get(url, verify=False) # 关闭ssl验证
#resp = requests.get(url)
print(resp.content.decode()) # should be SSLError
